The present invention relates to compression in general and in particular to compression for high-speed pixel data transport.
Real-time image generation at high resolutions generally requires fast, dedicated hardware for generating images (pixel color value arrays) from a geometric model. One problem with some image generators is that pixel data must be moved around quickly, so that the transport of data does not slow the entire operation. For example, if a real-time NTSC video image is being generated at a resolution of 640 pixels by 480 pixels at 30 frames/second, one second of video contains 9,216,000 pixels. Each of those pixels might be represented by 40 to 68 bits, eight bits for each of the red, green and blue components, 16 to 32 bits for Z depth and possibly eight to twelve bits for xe2x80x9calphaxe2x80x9d data (the alpha factor relates to transparency). The Z depth and alpha data often need to accompany a pixel so that the pixel can be processed in ways that might depend on the Z and alpha values for the pixel. For example, if two pixel values associated with the same screen location but two different objects are being considered to determine which object is visible at the location of the pixel, the Z value from the two pixel values is needed. If one of the objects is semitransparent, the alpha value for that object at that pixel location might be needed to calculate the pixel color value at that location.
With just 40 bits of information for each pixel, one second of video would require about 36 million bits; with 68 bits, the requirement is about 63 million bits. For real-time transport of the video, a channel bandwidth of about 36 to 63 mbs (million bits per second) is needed. It is well known to compress video data to reduce the size of the channel needed, especially since large areas of a video frame (such as background) might remain the same from frame to frame. One common standard for video compression is known as the MPEG (Motion Pictures Experts Group) standard. Good compression can be obtained with MPEG, but not if latency is taken into account.
Latency in an image generator is the time delay between the time the image generator receives a geometric model and the time the image generator outputs an image. A geometric model mathematically defines the objects that are present in a virtual xe2x80x9cworld spacexe2x80x9d. From that geometric model and a description of a view point and a view surface, the image generator generates an image that would be the view on the view surface from the view point, if the world space and the modeled objects actually existed. A real-time image generator might be used, for example, in a flight simulator. A flight simulator might operate by accepting input from sensors and a xe2x80x9cpilotxe2x80x9d and then display the resulting image that would be seen if the pilot was actually flying an airplane. If the latency between when the image generator receives the information about scene changes and a new image is generated is too long, the pilot will experience xe2x80x9csea sicknessxe2x80x9d since the video image will be too far out of sync with the pilot""s other stimuli.
A typical real-time video application might require an overall latency of 100 milliseconds (ms) or less. If the actual image processing takes up, for example, 60 ms of that allotted time, it would not be helpful to use compression to more quickly move the data around if the compression process has a latency of much more than 40 ms. Therefore, if compression is to be used in an image generator to more fully use a limited bandwidth, the latency added due to the compression must be minimized.
The present invention overcomes several disadvantages of the prior art methods and apparatus for generating images.
In one method according to the present invention, an encoder accepts an N byte set of values for each of a plurality of image components, with N being greater than one and, for each N byte set of values, identifies a compressed symbol length, K, wherein K is the smallest integer such that the difference between any two adjacent bytes is expressible in K bits or less, outputs an indication of K and outputs a K bit difference between the byte and an immediately prior byte, for each byte in the set.
A further understanding of the nature and advantages of the inventions herein may be realized by reference to the remaining portions of the specification and the attached drawings.